package cc.rengu.redp.bizimpl.upmp.dao;

import cc.rengu.redp.bizimpl.upmp.domain.WctFstInfo;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @author LiuYuLiang.LL
 */
public interface WctFstInfoMapper extends BaseMapper<WctFstInfo> {
    @Select("select WCT_SEC_NO from T_B_WCT_SEC_INFO where WCT_UP_NO = #{WCT_FST_NO} and status != '01'")
    public List<String> isExistSubDirect(String WCT_FST_NO);
    @Select("select WCT_FST_NO from T_B_WCT_FST_INFO where status != '01'")
    public List<String> findAllWctFstNo();
    @Select("select WCT_FST_NAME from T_B_WCT_SEC_INFO where status != '01'")
    public List<String> findAllWctFstName();
    
    @Select("select WCT_FST_NAME from T_B_WCT_SEC_INFO where WCT_FST_NAME = #{WCT_FST_NAME} and id <> #{id}")
    public List<String> findAllWctFstName(String WCT_FST_NAME, String id);

    @Select("select WCT_FST_NO from T_B_WCT_SEC_INFO where WCT_FST_NO = #{WCT_FST_NO}")
    public List<String> findwctFstNo(String WCT_FST_NO);

    @Select("select WCT_FST_NAME from T_B_WCT_SEC_INFO where WCT_FST_NAME =#{WCT_FST_NAME}")
    public List<String> findwctFstName(String WCT_FST_NAME);

    @Select("select distinct WCT_FST_TYPE from T_B_WCT_SEC_INFO where WCT_FST_TYPE like %#{q}%")
    public List<String> findone(String q);

    @Select("select * from T_B_WCT_SEC_INFO where WCT_FST_NO=#{WCT_FST_NO}")
    public WctFstInfo getByUk(String WCT_FST_NO);

}
